package com.imporven.sell.enums;

import lombok.Getter;

/**
 * @author imporven
 * @version 1.0.0
 * @date 2018-7-8 0:43
 * 返回结果枚举
 */
@Getter
public enum ResultEnum {

    SUCCESS(0,"成功"),
    PARAMETER_ERROR(10,"参数不正确"),
    CART_EMPTY(11,"购物车不能为空"),
    PRODUCT_NOT_EXIST(12,"商品不存在"),
    PRODUCT_STACK_NOT_ENOUGH(13,"库存不足"),
    ;

    /**
     * 编码
     */
    private Integer code;
    /**
     * 信息
     */
    private String msg;

    ResultEnum(Integer code, String msg){
        this.code = code;
        this.msg = msg;
    }

}
